unit uSBD_Crypto_Hash;
{
Copyright 2009 Sean B. Durkin

This file is part of SBD Crypto Library.
SBD Crypto Library is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

SBD Crypto Library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU Lesser General Public License for more details.

You should have received a copy of the Lesser GNU General Public License
along with SBD Crypto Library.  If not, see <http://www.gnu.org/licenses/>.
}
interface
uses Classes;

type

IHasher = interface
  ['{982870E4-EC9B-48CD-B882-17F58F0A7D1A}']
  procedure  Update( Source{in}: TMemoryStream);
  procedure  End_Hash( Digest: TStream);
  procedure  Burn;
  end;

IHash = interface
  ['{A3922AFC-C917-4364-9FD1-FD84A3E37558}']
    function  DigestSize: integer;  // in units of bits. Must be a multiple of 8.
    function  UpdateSize: integer; // Size that the input to the Update must be.
    function  DisplayName: string;
    function  ProgId: string;

    function  MakeHasher( const Params: IInterface): IHasher;
    end;


implementation

end.
